<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .main {
            width: 600px;
            height: 300px;
            background-color: rgb(255, 255, 255);
            border: 1px solid royalblue;
            margin: auto;
            display: flex;
            justify-content: space-evenly;
            flex-flow: row wrap;
        }

        .one {
            width: 100px;
            height: 100px;
            background-color: skyblue;
        }

        .two {
            width: 100px;
            height: 100px;
            background-color: lavender;
        }

        .three {
            width: 100px;
            height: 100px;
            background-color: rgb(222, 116, 134);
        }

        .four {
            width: 100px;
            height: 100px;
            background-color: rgb(187, 222, 164);
        }
    </style>
</head>

<body>
    <div class="main">
        <div class="one">1</div>
        <div class="two">2</div>
        <div class="three">3</div>
        <div class="four">4</div>
    </div>
</body>

</html>